package cn.edu.sdyu.ie.crs.domain;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import java.util.Date;

//@Schema(name = "教室环境信息")
@ApiModel("教室环境信息")
@Data
@Entity
public class ClassroomEnvironment {

    @ApiModelProperty("教室环境Id")
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Integer id;
    @ApiModelProperty("温度")
    private Integer temperature;  // 温度
    @ApiModelProperty("湿度")
    private Integer humidity;  // 湿度
    @ApiModelProperty("更新时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date updateTime;  // 更新时间
    @ApiModelProperty("教室ID")
    private Integer classroomId;
}
